package com.health.controller;

import com.health.domain.dto.MemberLoginDTO;
import com.health.domain.pojo.Member;
import com.health.domain.vo.Result;
import com.health.service.MemberService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ghy
 * @version 1.0
 * @since 2025-06-24 09:57
 */
@RestController
@RequestMapping("/member")
public class MemberController {

    @Autowired
    private MemberService memberService;

    @PostMapping("/login")
    public Result<Member> login(@RequestBody MemberLoginDTO memberLoginDTO) {
        return memberService.login(memberLoginDTO);
    }

}
